package com.Data;


import android.os.AsyncTask;
import com.SoapClasses.SoapPost_Likes;


public class Likes extends AsyncTask<Integer, String, String> {

    public static final int ACTION_ADD = 0;

    public static final int ACTION_DELETE = 1;

    private String[] data;

    public Likes(String[] data) {

        super();
        this.data = data;
    }

    @Override
    protected String doInBackground(Integer... action) {

        switch (action[0]) {
            case ACTION_ADD:
                return new SoapPost_Likes().addLike(data);

            case ACTION_DELETE:
                return new SoapPost_Likes().deleteLike(data);
            default:
                return null;
        }
    }

}
